package cn.com.api.service.impl.base;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import cn.com.api.entity.ApiU_resource;

import cn.com.api.mapper.ApiU_resourceMapper;

import cn.com.api.service.ApiU_resourceService;

/**
 * 
 **/
@Service
public class U_resourceServiceImplBase {
	@Autowired
	private ApiU_resourceMapper apiU_resourceMapper;
    
    // 根据id获取
	public ApiU_resource findU_resourceById(Integer id){
		ApiU_resource u_resource = apiU_resourceMapper.findU_resourceById( id );
		return u_resource;
	}
    
    //查看数据集
	public List<ApiU_resource> findU_resources(){
        List<ApiU_resource> u_resources = apiU_resourceMapper.findU_resources();
		return u_resources;
    }
   
    //根据条件查看数据集
	public List<Map<String, Object>> findU_resourcesByMap(HashMap condition){
        List<Map<String, Object>> u_resources = apiU_resourceMapper.findU_resourcesByMap(condition);
		return u_resources;
    }
    
	// 添加
	public int insertU_resource(ApiU_resource u_resource){
		int ret_I= apiU_resourceMapper.insertU_resource(u_resource);
		return ret_I;
	}

	// 修改
	public int updateU_resource(ApiU_resource u_resource){
		int ret_I= apiU_resourceMapper.updateU_resource(u_resource);
		return ret_I;
	}
	
    // 删除
	public int deleteU_resource(Integer id){
		int ret_I= apiU_resourceMapper.deleteU_resource( id );
		return ret_I;
	}
	
    // Foreign keys revelant		
		

	//region Indexs revelant
    
    
    
    
}


